<!DOCTYPE html>
<html>
	<head>
		<meta charset="UTF-8">
		<meta name="viewport" content="width=device-width, initial-scale=1,maximum-scale=1, user-scalable=no">
		<title>我的</title>
		<meta http-equiv="expires" content="0">
		<meta http-equiv="pragma" content="no-cache">
		<meta http-equiv="cache-control" content="no-cache">
		<link rel="stylesheet" href="../../../css/reset.css" />
		<link rel="stylesheet" href="../../../css/mui.min.css" />
		<link rel="stylesheet" href="../../../css/iconfont.css" />
		<link rel="stylesheet" href="../../../css/cmms.css" />
		<link rel="stylesheet" href="../../../css/sale/mine/mine.css" />
	</head>
	<body>
		<div id="mine" class="mui-content" v-cloak>
			<div class="wrap">
			    <header class="panel myHeader overflow">
			    	<span>
			    		<!--<i class="iconfont icon-touxiang"></i>-->
			    		<img src="../../../img/11.jpg" alt="" />
			    	</span>
			    	<span>{{infoList.name}}</span>
			    	<span class="right btn-tag" v-for="role in infoList.roles">{{role.name}}</span>
			    </header>
			    <section class="panel mySection">
			    	<ul>
			    		<!--<li class="overflow"  @tap="myMsg">
			    			<i class="iconfont icon-wodexiaoxi"></i>
			    			<span>我的消息</span>
			    			<i class="iconfont icon-fanhui right"></i>
			    		</li>-->
			    		<li class="overflow" @tap="myTeam">
			    			<i class="iconfont icon-tuandui-tianchong"></i>
			    			<span>我的团队</span>
			    			<i class="iconfont icon-fanhui right"></i>
			    		</li>
			    		<li class="overflow" @tap="myClinic">
			    			<i class="iconfont icon-icon1"></i>
			    			<span>我的诊所</span>
			    			<i class="iconfont icon-fanhui right"></i>
			    		</li>
			    		<li class="overflow noBottomBorder" @tap="toRoam">
			    			<i class="iconfont icon-tubiaozhizuomoban21"></i>
			    			<span>漫游登录</span>
			    			<i class="iconfont icon-fanhui right"></i>
			    		</li>
			    	</ul>
			    </section>
			    <footer class="panel mySection">
			    	<ul>
			    		<li class="overflow noBottomBorder" @tap="logout">
			    			<i class="iconfont icon-tuichu exit"></i>
			    			<span>退出登录</span>
			    		</li>
			    	</ul>
			    </footer>
			    <div id="mask" :class="{'hidden':!modelShow}"></div>
			    <div id="model" :class="{'hidden':!modelShow}">
			    	<p>退出登录</p>
			    	<p>确定要退出登录吗?</p>
			    	<p class="exitBtnBox">
			    		<span @tap="confirm" class="btn-primary">确定</span>
			    		<span @tap="cancel" class="btn-detail">取消</span>
			    	</p>
			    </div>
		    </div>
		</div>
		<script src="../../../js/mui.min.js"></script>
		<script src="https://res.wx.qq.com/open/js/jweixin-1.2.0.js"></script>
		<script src="../../../js/vue.js"></script>
		<script src="../../../js/cmms.js?time=333"></script>
		<script>
			new Vue({
				el:"#mine",
				data:{
					infoList:[],
					modelShow:'',
					romaFlag:true//漫游登陆
				},
				mounted(){
					this.loadInfo();
				},
				methods:{
					loadInfo(){
						let _this = this;
						AT.muiAjax('/partner-sale/hosptal/getName','post',
						{},
						function(res){
							console.log(res);
							_this.infoList = res;
						});
					},
					myMsg(){
						location.href = "mineMsg.html"
					},
					myTeam(){
						location.href = "mineTeam.html"
					},
					myClinic(){
						location.href = "../clinic/clinic.html"
					},
					/*漫游登录设flag*/
					toRoam(){
						location.href = "../clinic/clinic.html";
					},
					/*退出弹框*/
					logout(){
						this.modelShow = true;
						
					},
					/*确认*/
					confirm(){
						this.modelShow = false;
						AT.muiAjax('/passport/logout','post',{},function(realData){
							localStorage.removeItem('sale_token');
							localStorage.clear();
							location.href = "https://open.weixin.qq.com/connect/oauth2/authorize?appid=wx50a81908477971c2&redirect_uri=https%3a%2f%2flis.ulabcare.com%2fant-dev%2flogin.html&response_type=code&scope=snsapi_base&state=wx50a81908477971c2#wechat_redirect"
						});
						
					},
					/*取消*/
					cancel(){
						this.modelShow = false;
					}
				}
			})
		</script>
	</body>
</html>
